<?php

namespace app\api\validate;

use think\Validate;

class MakeOrder extends Validate
{
    protected $rule = [
        'make_id' => "require",
        "make_time"=> "require",
        'name'     =>"require",
        "phone"    => "require|mobile",
        "end_address" => "require",
        "my_address"     => "require",
        "lat" => "require",
        "lng"  => "require",
        "agree"        => "require",
    ];

    protected $message = [
        'make_id.require' => '请选择服务项目',
        'make_time.require' => '请选择预约时间',
        'name.require' => '请填写预约人姓名',
        'phone.require'      => '请填写手机号码',
        'phone.mobile'       => '手机号格式错误',
        'end_address.require' => '请填写目的地',
        'my_address.require'     => '请获取我的位置',
        'lat.require' => '请填写纬度',
        'lng.require'  => '请填写经度',
        'agree.require' => '请您阅读并同意《服务协议》'
    ];

}